home *** CD-ROM | disk | FTP | other *** search
/ Champak 106 / Vol 106.iso / games / garfield.swf / scripts / DefineSprite_17_odie_wait / frame_1 / DoAction.as
Encoding:
Text File  |  2010-04-12  |  250 b   |  15 lines

  1. function wait_for_ball(obj)
  2. {
  3.    if(obj._parent.ball_mov._y > 300)
  4.    {
  5.       stop_wait();
  6.    }
  7. }
  8. function stop_wait()
  9. {
  10.    clearInterval(timer);
  11.    _parent.odie_replace(0);
  12. }
  13. var timer = -1;
  14. timer = setInterval(wait_for_ball,50,this);
  15.